<template>
    <div class="content">
        <div class="col-bg overview-info overview-info2 mt24">
            <div class="info-title">
                <Row type="flex" justify="space-between" class="code-row-bg">
                    <Col span="4">基本信息</Col>
                </Row>
            </div>
            <Row class="ivu-row-info" :gutter="20">
                <Col span="24">用户名：{{detail.real_name}}</Col>
                <Col span="24">手机号： {{detail.mobile}}   </Col>
                <Col span="24">角色：<span v-for="(item,index) in roleList" v-if="detail.user_type_id==item.value">{{item.label}}</span></Col>
                <Col span="24" v-if="detail.supervise_org_id">监管单位：{{detail.mobile}}</Col>
            </Row>
        </div>
    </div>
</template>
<script>
    import { userInfo } from '@/api/systemManage'
    export default {
        data () {
            return {
                data1: [],
                detail:{},
                roleList:[
                    {
                        value:'1',
                        label:'监管用户'
                    },{
                        value:'2',
                        label:'运营用户'
                    }
                ],
            }
        },
        created(){
            this.getList();
        },
        methods: {
            //获取列表
            getList(){
                let that = this;
                let data ={
                    id:this.$route.query.id,
                }
                userInfo(data).then(res => {
                    console.log(res)
                    that.detail = res.data
                })
                    .catch(err => {
                        // console.log('err: ', err);

                    })
            },
        }
    }
</script>
